import React from 'react';
import './App.css';


const Home = (props) => {
  return <div>首页</div>;
};

const List = (props) => {
  return <div>列表页</div>;
};

import { HashRouter, Route, Link, NavLink } from 'react-router-dom';


class App extends React.Component {
  render() {
    return (
      <div className="App">
        <HashRouter>
          <nav>
            <Link to="/">切换首页</Link>
            <Link to="/list">切换列表页</Link>
          </nav>
          <section>
            <Route path="/" component={Home}></Route>
            <Route path="/list" component={List}></Route>
          </section>
        </HashRouter>
      </div>
    );
  }
}

export default App;
